﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using AukcjeInternetowe.Models;

namespace AukcjeInternetowe.Providers
{
    public class TestDataProvider : IDataProvider
    {
        public List<ItemCategoryModel> GetItemsForCategory(int categoryId)
        {
            List<ItemCategoryModel> items = new List<ItemCategoryModel>();

            items.Add(new ItemCategoryModel()
            {
                Id = 1,
                ActualPrice = 124.5,
                Title = "Golarka do owiec PHILIPS",
                EndDate = new DateTime() + new TimeSpan(1, 0, 0),
                CategoryId = 1,
                Description = "Testowa aukcja",
                UserId = 1
            });

            items.Add(new ItemCategoryModel()
            {
                Id = 2,
                ActualPrice = 95.4,
                Title = "Glebogryzarka Husqvarna",
                EndDate = new DateTime() + new TimeSpan(5, 30, 0),
                CategoryId = 1,
                Description = "Testowa aukcja",
                UserId = 1
            });

            return items;
        }

        public List<ItemCategoryModel> GetAllItems()
        {
            List<ItemCategoryModel> items = new List<ItemCategoryModel>();

            items.Add(new ItemCategoryModel()
            {
                Id = 1,
                ActualPrice = 124.5,
                Title = "Golarka do owiec PHILIPS",
                EndDate = new DateTime() + new TimeSpan(1, 0, 0),
                CategoryId = 1,
                Description = "Testowa aukcja",
                UserId = 1
            });

            items.Add(new ItemCategoryModel()
            {
                Id = 2,
                ActualPrice = 95.4,
                Title = "Glebogryzarka Husqvarna",
                EndDate = new DateTime() + new TimeSpan(5, 30, 0),
                CategoryId = 1,
                Description = "Testowa aukcja",
                UserId = 1
            });

            items.Add(new ItemCategoryModel()
            {
                Id = 3,
                ActualPrice = 10.01,
                Title = "Bulbulator klasyczny",
                EndDate = new DateTime() + new TimeSpan(23, 59, 0),
                CategoryId = 1,
                Description = "Testowa aukcja",
                UserId = 1
            });

            return items;
        }

        public void Dispose()
        {
        }
    }
}
